#include "Solution.h"

Solution::Solution(/* args */)
{
}

Solution::~Solution()
{
}

int Solution::removeDuplicates(vector<int>& nums) 
{
    int slow = 0;
    for (size_t i = 1; i < nums.size(); i++)
    {
        if (nums[i] != nums[slow]) {
            nums[++slow] = nums[i];
        }
    }
    return slow + 1;
}